<template>
  <div class="muscle">
    <aplayer
      v-if="showPlayer"
      ref="videoPlayRef"
      :music="videoPlay"
      :autoplay="true"
    ></aplayer>
    <i class="el-icon-close close" @click="musicClose"></i>
  </div>
</template>

<script>
import aplayer from "vue-aplayer";
export default {
  name: "LogAuditManagement",
  components: {
    aplayer,
  },
  props: {
    videoPlay: {
      type: Object,
      default: () => {
        return {
          title: "名称",
          artist: "音频",
          src: "",
          pic: "https://moeplayer.b0.upaiyun.com/aplayer/secretbase.jpg",
        };
      },
    },
    showPlayer: {
      type: Boolean,
      default: false,
    },
  },

  data() {
    return {};
  },
  methods: {
    musicClose() {
      this.$emit("musicClose", false);
    },
  },
};
</script>

<style scoped lang='scss'>
.muscle {
  width: 80%;
  position: absolute;
  z-index: 999;
  bottom: 0;
  overflow: hidden;
  .close {
    position: absolute;
    right: 20px;
    top: 10px;
    cursor: pointer;
  }
}
</style>